<!DOCTYPE html>
<html>
<head th:include="include :: header"></head>
<body class="layui-bg-white">
<div class="layui-form" style="padding:20px;">
	<div class="layui-form-item">
		<label class="layui-form-label"><span class="required">*</span>任务名称：</label>
		<div class="layui-input-block">
			<input type="text" name="jobName" lay-verify="required" placeholder="请输入任务名称" autocomplete="off" class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label"><span class="required">*</span>任务分组：</label>
		<div class="layui-input-block">
			<input type="text" name="jobGroup" lay-verify="required" placeholder="请输入任务分组" autocomplete="off" class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label"><span class="required">*</span>任务类：</label>
		<div class="layui-input-block">
			<input type="text" name="beanClass" lay-verify="required" placeholder="请输入任务类" autocomplete="off" class="layui-input">
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">CORN表达式：</label>
		<div class="layui-input-block">
			<input type="text" name="cron" placeholder="请输入CORN表达式" autocomplete="off" class="layui-input">
		</div>
	</div>
	<div class="layui-row layui-form-item">
		<div class="layui-col-md6">
			<label class="layui-form-label">任务状态：</label>
			<div class="layui-input-block">
				<input type="checkbox" lay-skin="switch" lay-filter="switchState" lay-text="开启|关闭" checked="checked">
				<input type="hidden" name="jobStatus" id="state" value="1">
			</div>
		</div>
	</div>
	<div class="layui-form-item">
		<label class="layui-form-label">任务描述：</label>
		<div class="layui-input-block">
			<input type="text" name="description" placeholder="请输入任务描述" autocomplete="off" class="layui-input">
		</div>
	</div>
	<div class="layui-form-item layui-hide">
		<input type="button" lay-submit lay-filter="LAY-operate-submit" id="LAY-operate-submit" value="确认">
	</div>
</div>
<div th:include="include :: footer"></div>
<script type="text/javascript">
	layui.config({
		base: ctx + '/layuiadmin/' //静态资源所在路径
	}).extend({
		index: 'lib/index'         //主入口模块
	}).use(['index', 'form'], function () {
		var $ = layui.$, form = layui.form, laydate = layui.laydate;

		form.on('switch(switchState)', function (data) {
			if (data.elem.checked == true) {
				$('#state').val('1');
			} else {
				$('#state').val('0');
			}
		});

		form.verify(commonJs.form.verify);
	})
</script>
</body>
</html>

